//路由
const koaRouter = require("@koa/router");

//前缀
const loginRouter = new koaRouter({ prefix: "/login" });

const { login, loginTest } = require("../controller/login_controller");

const { verifyLogin, verifyAuth } = require("../middleware/login.middleware");

loginRouter.post("/", verifyLogin, login);
// loginRouter.get("/test", loginTest);
// loginRouter.get("/list", verifyAuth, (ctx, next) => {
//   console.log(ctx);
//   ctx.body = ctx.user;
// });

module.exports = loginRouter;
